package com.dsdl.chatapp.module.chat;

import com.dsdl.chatapp.data.SocketMessage;
import com.dsdl.chatapp.data.source.ChatRepository;

/**
 * Created by zzg on 2016/8/2.
 */
public class ChatPresenter implements ChatContract.Presenter {
    private final ChatContract.View mChatContract;
    private final ChatRepository mChatRepository;

    public ChatPresenter(ChatRepository chatRepository, ChatContract.View chatView) {
        this.mChatRepository = chatRepository;
        this.mChatContract = chatView;
        chatView.setPresenter(this);
    }

    @Override
    public void sendMessage(SocketMessage message) {
        mChatRepository.saveMsg(message);
    }

    @Override
    public void start() {

    }
}
